package com.googlecode.mindlistening.graph;

import prefuse.visual.EdgeItem;
import prefuse.visual.NodeItem;
import prefuse.util.force.DragForce;
import prefuse.util.force.ForceSimulator;
import prefuse.util.force.NBodyForce;
import prefuse.util.force.SpringForce;
import prefuse.action.layout.graph.ForceDirectedLayout;

/**
 * VizsterLayout
 *  
 * @version 1.0
 * @author <a href="http://jheer.org">Jeffrey Heer</a> prefuse(AT)jheer.org
 */
public class VizsterLayout extends ForceDirectedLayout {

//    private float normal = 2E-5f;
//    private float slack1 = 2E-6f;
//    private float slack2 = 2E-7f;
    
    private float NO_TENSION = 0f;
    private float SINGLETON  = 8E-5f;
    private float ORBIT      = 1E-5f;
    private float EXTRACOMM  = 1E-6f;
    private float NORMAL     = 2E-5f;
    
    public VizsterLayout(String graph) {
        super(graph);
        
        // initialize the force simulator
        ForceSimulator fsim = new ForceSimulator();
        fsim.addForce(new NBodyForce(-2.3f, -0.1f, 0.2f));
        fsim.addForce(new SpringForce(0.1f, 150f));
        fsim.addForce(new DragForce(-0.005f));
        setForceSimulator(fsim);
        

    } //
    


    

    

    

    
} // end of class VizsterLayout
